1. Field of the Invention
The present invention generally relates to a management system, and more particularly to a power management system and method thereof.
2. Description of Related Art
The handheld devices or portable devices, such as a USB flash, not only can be used to transfer data, but also can be used to perform charging by plugging it in the interface connecting port (e.g. USB connecting port) of the computer. However, it has the limitation about the number of the interface connecting port in the computer. In order to communicate with the computer for more handheld devices, the USB hub is developed to connect the handheld devices and the computer.
Referring now to FIG. 1A, an architecture diagram illustrating the traditional power management system according to an embodiment is shown. The power management system 1 includes a host computer 11 and a USB hub 13. The USB hub 13 includes a plurality of sub connecting ports 13a-13c which is provided at least one portable device 15 to plug in to interact with the host computer 11. The host computer 11 includes a CPU 111, a south north bridge 113, a memory 115, and an interface connecting port 117. The CPU 111 is configured to control the whole operations within the host computer 11. The south north bridge 113 is configured to control the units within the host computer 11, such as the memory 115 and input/output circuit, to transmit signals or data with the CPU 111. The memory 115 is configured to store the operating system (OS) and a plurality of drivers, the operating system would be loaded from the memory 115 when the host computer 11 is power-on, and the corresponding drivers would also be loaded based on the hardware architecture configured in the host computer 11 to control the operation of the hardware.
The interface connecting port 117 is configured to interface the USB hub 13 to the host computer 11. Take a USB connecting port as example, there is a USB host controller 1131 within the south north bridge 113, which controls the portable device 15 that are plugged in the sub connecting ports 13a-13c. 
Referring now to FIG. 1B, an architecture diagram illustrating a USB switch of the USB hub according to one embodiment is shown. As shown in FIG. 1B, a USB switch 14 of the USB hub 13 is corresponding to one of the sub connecting ports 13a-13c, such as the sub connecting port 13a. The USB switch 14 is controlled by the USB host controller 1131 of the host computer 11 to switch whether the sub connecting port 13a connects a data transmission circuit 16 or a dedicated charge circuit 17. The USB data transmission differential pairs (e.g. D+/D− signal ends) of the sub connecting port 13a can be coupled to the interface connecting port 117 of the host computer by the data transmission circuit 16, and the USB data transmission differential pairs of the sub connecting port 13a can be shorted (e.g. couple with an impedance unit 12 such as a resistance) by the dedicated charge circuit 17 to enable charging function. According to another embodiment, the USB switch 14 can be disposed in any position on the USB hub 13. Specifically, if the USB hub 13 is in an active mode, the portable device 15 plugged-in can transmit data with the host computer 11 each other through the data transmission circuit 16. If the USB hub 13 is in a suspend mode (or sleep mode), the USB switch 14 is switched to use the dedicated charge circuit 17 rather than the data transmission circuit 16, and USB hub 13 receives the electricity (or the independent power of the USB hub 13, not shown) provided from the host computer 11 through the interface connecting port 117 to perform charging for the portable devices 15 (whether any portable device 15 is plugged-in or not).
Broadly speaking, the operating system (such as Microsoft Windows, Linux, and Apple Mac OS, includes the default driver for USB hub 13) of the host computer includes a predetermined USB hub driver which detects whether the USB hub 13 connects the portable devices 15. If there is not any portable device 15 coupling to the USB hub 13 for a while, the USB hub 13 may be controlled to be in the suspend mode, and the USB switch 14 is switched to use the dedicated charge circuit 17 to perform charging. However, the host computer 11 is still in the active mode, that is, due to the behavior of the predetermined USB hub driver as described, the USB hub 13 cannot detect actually power mode of the host computer 11, and cannot enter suspend mode according to the actually power mode. In this case, the sleep charging function of the USB hub 13 may not be implemented. Furthermore, when the host computer is in a host active state (S0 state), even user plugs-in the portable device 15 in the sub connecting ports 13a-13c, the USB hub 13 cannot transmit data of the portable device 15 because the USB hub 13 enters suspend mode, and which causes users to suppose the sub connecting ports 13a-13c cannot work or be destroyed.
In view of the above drawback, a need has arisen to propose a novel power management system and method thereof in which the mode of the USB hub can directly reflect the power mode of the host computer.